//
//  User.m
//  UI_豆瓣
//
//  Created by dllo on 15/11/2.
//  Copyright © 2015年 蓝鸥科技. All rights reserved.
//

#import "User.h"

@implementation User

- (void)dealloc
{
    [_userName release];
    [_passworld release];
    [super dealloc];
}

//对model进行编码
-(void)encodeWithCoder:(NSCoder *)aCoder
{
    [aCoder encodeObject:self.userName forKey:@"userName"];
    [aCoder encodeObject:self.passworld forKey:@"passworld"];
}

//对model进行解码
-(instancetype)initWithCoder:(NSCoder *)aDecoder
{
    self = [super init];
    if (self) {
        self.userName = [aDecoder decodeObjectForKey:@"useName"];
        self.passworld = [aDecoder decodeObjectForKey:@"passworld"];
    }
    return self;
}

@end
